package edu.whu.rose.clock.kps.datastruct;

public class SimpleSubgraphVertex {

	private final int subgraph_id;
	private final int vertex_id;

	public SimpleSubgraphVertex(int subgraph_id, int vertex_id) {
		this.subgraph_id = subgraph_id;
		this.vertex_id = vertex_id;
	}

	public boolean equals(Object obj) {
		if (obj == null || !(obj instanceof SimpleSubgraphVertex)) {
			return false;
		}
		SimpleSubgraphVertex other = (SimpleSubgraphVertex)obj;
		return subgraph_id == other.getSubgraph_id() && vertex_id == other.getVertex_id();
	}
	
	public int hashCode() {
		int result = 17;
		result = 37 * result + subgraph_id;
		result = 37 * result + vertex_id;
		return result;
	}

	public int getSubgraph_id() {
		return subgraph_id;
	}

	public int getVertex_id() {
		return vertex_id;
	}

}
